package org.dzq.designmode.facade;

/**
 * @ClassName: FacadeService
 * @Package: org.dzq.designmode.facade
 * @author: 越
 * @date: 2023/6/14 19:54
 * @Description: 外观模式（门面模式）符合开闭原则
 */
public class FacadeService {

    private SubSystemA subSystemA;
    private SubSystemB subSystemB;
    private SubSystemC subSystemC;

    public FacadeService(){
        subSystemA = new SubSystemA();
        subSystemB = new SubSystemB();
        subSystemC = new SubSystemC();
    }

    public void doAll(){
        subSystemA.doA();
        subSystemB.doB();
        subSystemC.doC();
    }
}
